﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="Order.aspx.cs" Inherits="OLMS.Order" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div class="order-content">
        <div class="pure-g">
            <div class="pure-u-3-5">
                <h2>我的订单</h2>
            </div>
            <div class="pure-u-2-5">
                <div class="pure-g">
                    <div class="pure-u-1-3">
                        <asp:LinkButton ID="btnOrderShow" runat="server" CssClass="button-default pure-button pure-button-primary" OnClick="btnOrderShow_Click">待处理订单</asp:LinkButton>
                    </div>
                    <div class="pure-u-1-3">
                        <asp:LinkButton ID="btnOrderHistrory" runat="server" CssClass="button-default pure-button" OnClick="btnOrderHistrory_Click">历史订单</asp:LinkButton>
                    </div>
                    <div class="pure-u-1-3">
                        <asp:LinkButton ID="btnChgPwd" runat="server" CssClass="button-default pure-button" OnClick="btnChgPwd_Click">密码修改</asp:LinkButton>
                    </div>
                </div>
            </div>
            <div class="pure-u-1">
                <table class="pure-table pure-table-bordered pure-table-striped">
                    <thead>
                        <tr>
                            <th>编号</th>
                            <th>收货人</th>
                            <th>电话</th>
                            <th>下单日期</th>
                            <th>状态</th>
                            <th>金额</th>
                            <th>操作</th>
                        </tr>
                    </thead>
                    <tbody>
                        <asp:Repeater ID="repOrdersList" runat="server">
                            <ItemTemplate>
                                <tr>
                                    <td><%# Eval("OrderId") %></td>
                                    <td><%# Eval("Username") %></td>
                                    <td><%# Eval("Phone") %></td>
                                    <td><%# Eval("OrderDate","{0:D}") %></td>
                                    <td><%# Eval("OrderStatusName") %></td>
                                    <td><%# Eval("Total","{0:C}元") %></td>
                                    <td>
                                        <asp:LinkButton ID="btnDetail" runat="server" CommandArgument='<%# Eval("OrderId") %>' CssClass="button-default pure-button" OnCommand="btnDetail_Command">订单详情</asp:LinkButton>
                                        <asp:LinkButton ID="btnBack" runat="server" CommandArgument='<%# Eval("OrderId") %>' CssClass="button-default pure-button" OnCommand="btnBack_Command" Visible='<%# Convert.ToInt32(Eval("OrderStatus"))<3 %>'>退货</asp:LinkButton>
                                        <asp:LinkButton ID="btnComplate" runat="server" CommandArgument='<%# Eval("OrderId") %>' CssClass="button-default pure-button" OnCommand="btnComplate_Command" Visible='<%# Convert.ToInt32(Eval("OrderStatus"))<3 %>'>确认收货</asp:LinkButton>
                                    </td>
                                </tr>
                            </ItemTemplate>
                        </asp:Repeater>
                    </tbody>
                </table>
            </div>
        </div>
    </div>

</asp:Content>
